package com.raymond.cmpp.msg.request;

import com.raymond.client.msg.AbstractMessage;
import com.raymond.cmpp.enums.CommandIdType;

/**
 * 状态报告和上行请求
 *
 * @author :  raymond
 * @version :  V1.0
 * @date :  2021-08-06 10:45
 */
public class DeliverRequestMessage extends AbstractMessage {
    /** 流水号 **/
    private long msgId;
    /** 目的号码。SP的服务代码，或者是前缀为服务代码的长号码；该号码是手机用户短消息的被叫号码。 **/
    private String destId;
    /** 业务标识，是数字、字母和符号的组合。 **/
    private String serviceId;
    /** 源终端MSISDN号码（状态报告时填为CMPP_SUBMIT消息的目的终端号码）。 **/
    private String srcTerminalId;
    /** 源终端号码类型，0：真实号码；1：伪码。**/
    private short srcTerminalType;
    /** 是否为状态报告：0：非状态报告；1：状态报告。 **/
    private short registeredDelivery = 0;
    /** 点播业务使用的LinkID，非点播类业务的MT流程不使用该字段。 **/
    private String linkId;
    /** 保留。 **/
    private String reserved;
    /** 0是普通GSM 类型，点到点方式 ,127 :写sim卡 **/
    private short tpPid = 0;
    /** 0:msgContent不带协议头。1:带有协议头 **/
    private short tpUdhi = 0;
    /**信息格式：0：ASCII串；3：短信写卡操作；4：二进制信息；8：UCS2编码；15：含GB汉字。**/
    private short msgFmt;
    /** 消息长度，取值大于或等于0。 **/
    private short msgLength = 140;
    /** 消息内容。 **/
    private byte[] msgContentBytes;
    /** 是否是状态报告 **/
    private boolean isReport;
    /** 状态报告响应实体。 **/
    private ReportRequestMessage reportRequestMessage;

    public DeliverRequestMessage(int sequenceId) {
        super(sequenceId);
    }

    @Override
    public int getCommandId() {
        return CommandIdType.DELIVER_REQUEST.getCommandId();
    }

    public long getMsgId() {
        return msgId;
    }

    public void setMsgId(long msgId) {
        this.msgId = msgId;
    }

    public String getDestId() {
        return destId;
    }

    public void setDestId(String destId) {
        this.destId = destId;
    }

    public String getServiceId() {
        return serviceId;
    }

    public void setServiceId(String serviceId) {
        this.serviceId = serviceId;
    }

    public String getSrcTerminalId() {
        return srcTerminalId;
    }

    public void setSrcTerminalId(String srcTerminalId) {
        this.srcTerminalId = srcTerminalId;
    }

    public short getSrcTerminalType() {
        return srcTerminalType;
    }

    public void setSrcTerminalType(short srcTerminalType) {
        this.srcTerminalType = srcTerminalType;
    }

    public short getRegisteredDelivery() {
        return registeredDelivery;
    }

    public void setRegisteredDelivery(short registeredDelivery) {
        this.registeredDelivery = registeredDelivery;
    }

    public String getLinkId() {
        return linkId;
    }

    public void setLinkId(String linkId) {
        this.linkId = linkId;
    }

    public String getReserved() {
        return reserved;
    }

    public void setReserved(String reserved) {
        this.reserved = reserved;
    }

    public short getTpPid() {
        return tpPid;
    }

    public void setTpPid(short tpPid) {
        this.tpPid = tpPid;
    }

    public short getTpUdhi() {
        return tpUdhi;
    }

    public void setTpUdhi(short tpUdhi) {
        this.tpUdhi = tpUdhi;
    }

    public short getMsgFmt() {
        return msgFmt;
    }

    public void setMsgFmt(short msgFmt) {
        this.msgFmt = msgFmt;
    }

    public boolean isReport() {
        return isReport;
    }

    public void setReport(boolean report) {
        isReport = report;
    }

    public short getMsgLength() {
        return msgLength;
    }

    public void setMsgLength(short msgLength) {
        this.msgLength = msgLength;
    }

    public byte[] getMsgContentBytes() {
        return msgContentBytes;
    }

    public void setMsgContentBytes(byte[] msgContentBytes) {
        this.msgContentBytes = msgContentBytes;
    }

    public ReportRequestMessage getReportRequestMessage() {
        return reportRequestMessage;
    }

    public void setReportRequestMessage(ReportRequestMessage reportRequestMessage) {
        this.reportRequestMessage = reportRequestMessage;
    }
}
